<include file="./Application/Admin/View/Public/htmlheader.html" />
<include file="./Application/Admin/View/Public/header.html" />
<include file="./Application/Admin/View/Public/left.html" />

<ol class="breadcrumb">
    <li><a href="/Admin">首页</a></li>
    <li class="active">修改试卷</li>
</ol>
<form action="/Admin/Paper/modifyPaper" method="post">
    <div class="row">
        <div class="col-lg-3 text-right"><span class="red">*</span>试卷名称：</div>
        <div class="col-lg-3"><input type="text" name="name" value="{$data['name']}" class="form-control" /></div>
    </div>
    <br />
    <div class="row">
          <div class="col-lg-3 text-right"><p>答题总时间：</p></div>
          <div class="col-lg-3"><input type="text" name="question_time"  value="{$data['question_time']}" placeholder="请输入整数，例如 30" class="form-control"/></div>
    </div>
    <br/>
    <div class="row">
         <div class="col-lg-3 text-right"><p>试卷选题：</p></div>
              <div class="col-lg-9">
                   <volist name="tagList" id="vo">
                           <div class="tag" style="line-height:30px;">
                                <span style="font-size:14px; margin-right:20px;">{$vo.name}:</span>
                                      <volist name="vo['question']" id="voo">
                                           <span><label><input type="checkbox" name="titles[]" value="{$voo.id}" class="title{$voo.id}" /> {$voo.title}</label></span>
                                       </volist>
                           </div>
                   <hr style="margin:0" />
                   </volist>
              </div>
          </div>
          <br/>
    <input type="hidden" name="id" value="{$data['id']}">
    <br />
    <div class="row">
        <div class="col-lg-3"></div>
        <div class="col-lg-3"><button type="submit" class="btn btn-primary">确定</button></div>
    </div>
    
</form>
<script>
var titles = "{$data.titles}";
if(titles != ""){
	var title = titles.split(",");
	for(var i=0;i<title.length;i++){
			$(".title"+title[i]+"").attr("checked", true);
        }
	}
</script>
<include file="./Application/Admin/View/Public/footer.html" />